package com.hntest.entity;

import com.hntest.util.BidConst;
import org.springframework.format.annotation.DateTimeFormat;

import java.math.BigDecimal;
import java.util.Date;

/**
 * 投标对象模型表
 * @author xu
 *
 */
public class Bid extends BaseDomain{

	/**
	 * 
	 */
	private static final long serialVersionUID = -7130332747314009386L;
	private int bidid;//投标id
	private BigDecimal actualrate = BidConst.ZERO; //年利率
	private BigDecimal availableAmount = BidConst.ZERO; //至少投资限额
	private BigDecimal bidmoney =  BidConst.ZERO;//投了多少r
	private long bidrequest_id;//来自于哪个借款标
	private LoginInfo biduser_id;//投标人id
	@DateTimeFormat(pattern = "yyyy-MM-dd")
	private Date bidtime;//投标时间
	private String bidrequesttitle;//标的title
	private BidRequest bidRequest;//一对多  为了附件一个 【还款方式】
	private LoginInfo logininfo;//association

	public Bid(int bidid, BigDecimal actualrate, BigDecimal availableAmount, BigDecimal bidmoney, long bidrequest_id, LoginInfo biduser_id, Date bidtime, String bidrequesttitle, BidRequest bidRequest, LoginInfo logininfo) {
		this.bidid = bidid;
		this.actualrate = actualrate;
		this.availableAmount = availableAmount;
		this.bidmoney = bidmoney;
		this.bidrequest_id = bidrequest_id;
		this.biduser_id = biduser_id;
		this.bidtime = bidtime;
		this.bidrequesttitle = bidrequesttitle;
		this.bidRequest = bidRequest;
		this.logininfo = logininfo;
	}

	public Bid (){}

	public LoginInfo getBiduser_id() {
		return biduser_id;
	}

	public void setBiduser_id(LoginInfo biduser_id) {
		this.biduser_id = biduser_id;
	}

	public LoginInfo getLogininfo() {
		return logininfo;
	}

	public void setLogininfo(LoginInfo logininfo) {
		this.logininfo = logininfo;
	}

	public static long getSerialVersionUID() {
		return serialVersionUID;
	}

	public int getBidid() {
		return bidid;
	}

	public void setBidid(int bidid) {
		this.bidid = bidid;
	}

	public BigDecimal getActualrate() {
		return actualrate;
	}

	public void setActualrate(BigDecimal actualrate) {
		this.actualrate = actualrate;
	}

	public BigDecimal getAvailableAmount() {
		return availableAmount;
	}

	public void setAvailableAmount(BigDecimal availableAmount) {
		this.availableAmount = availableAmount;
	}

	public BigDecimal getBidmoney() {
		return bidmoney;
	}

	public void setBidmoney(BigDecimal bidmoney) {
		this.bidmoney = bidmoney;
	}

	public long getBidrequest_id() {
		return bidrequest_id;
	}

	public void setBidrequest_id(long bidrequest_id) {
		this.bidrequest_id = bidrequest_id;
	}



	public Date getBidtime() {
		return bidtime;
	}

	public void setBidtime(Date bidtime) {
		this.bidtime = bidtime;
	}

	public String getBidrequesttitle() {
		return bidrequesttitle;
	}

	public void setBidrequesttitle(String bidrequesttitle) {
		this.bidrequesttitle = bidrequesttitle;
	}

	public BidRequest getBidRequest() {
		return bidRequest;
	}

	public void setBidRequest(BidRequest bidRequest) {
		this.bidRequest = bidRequest;
	}





}
